home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Atari Compendium
/
The Atari Compendium (Toad Computers) (1994).iso
/
files
/
umich
/
utils
/
crunch.arc
/
CRUNCH80.DOC
< prev
Wrap
Text File
|
1985-11-19
|
5KB
|
138 lines
P✓P✓P✓Pr✓r✓r✓ro✓o✓o✓og✓g✓g✓gr✓r✓r✓ra✓a✓a✓am✓m✓m✓m f✓f✓f✓fi✓i✓i✓il✓l✓l✓le✓e✓e✓e c✓c✓c✓cr✓r✓r✓ru✓u✓u✓un✓n✓n✓nc✓c✓c✓ch✓h✓h✓he✓e✓e✓er✓r✓r✓r V✓V✓V✓V3✓3✓3✓3.✓.✓.✓.3✓3✓3✓3
C✓C✓C✓Co✓o✓o✓op✓p✓p✓py✓y✓y✓yr✓r✓r✓ri✓i✓i✓ig✓g✓g✓gh✓h✓h✓ht✓t✓t✓t 5✓5✓5✓5/✓/✓/✓/9✓9✓9✓9/✓/✓/✓/1✓1✓1✓19✓9✓9✓98✓8✓8✓88✓8✓8✓8 b✓b✓b✓by✓y✓y✓y M✓M✓M✓M.✓.✓.✓.S✓S✓S✓S.✓.✓.✓.P✓P✓P✓Po✓o✓o✓ow✓w✓w✓we✓e✓e✓el✓l✓l✓ll✓l✓l✓l
F✓F✓F✓Fi✓i✓i✓il✓l✓l✓le✓e✓e✓e:✓:✓:✓: C✓C✓C✓CR✓R✓R✓RU✓U✓U✓UN✓N✓N✓NC✓C✓C✓CH✓H✓H✓H3✓3✓3✓33✓3✓3✓3.✓.✓.✓.T✓T✓T✓TT✓T✓T✓TP✓P✓P✓P
THIS PROGRAM IS PUBLIC DOMAIN.
Permission is granted to copy this program along with it's documentation
as long as such copying is not for profit.
This program will crunch an GEMDOS executable file (i.e. files with
extensions .PRG, .TOS, .TTP & .APP) into another single, but shorter, executable
file, thus using up less disk space, and also loading slightly quicker. Although
this file will be smaller than the original, it will still execute exactly as
did the longer original.
The program requires a command line of the following format:-
[-[h][d][u][i]] <pathname>
Where:-
h Will hold screen when program has finished (useful if you are running from
the desktop).
d Will stop the deletion of the original file. (i.e. will give the file the
extension .CRU if crunching and .UCR if uncrunching instead of using the
original file extension and thus deleting the original file).
u Will cause the program to only uncrunch, crunched files, ignoring all others.
i Will cause the program to ignore errors (useful when one file is generating a
read error)
If you use any of the above qualifiers you must precede them all with a '-'
character.
<pathname> is a standard GEMDOS path
e.g.
-hu a:\bits\*.*
Hold screen on exit, uncrunch all files in folder "bits" on drive A.
d:\assembler\programs\*.prg
Crunch all .PRG files in folder "programs" in folder "assembler" on drive D.
-h *.*
Crunch all files on current drive and hold screen on exit.
Crunching files
---------------
When a file is crunched successfully it will be written back on to disk
with the same name as it had before, thus erasing the original. There is no need
to worry about this though, as if a file doesn't work when crunched it can be
uncrunched and restored to exactly as it was before. This shouldn't happen
though as from about 90+ files I have crunched all have worked perfectly when
crunched (honestly!). (You can disable this deletion of the original file by
specifying the 'd' qualifier in the command line). Some files will of course not
crunch at all and some may only be reduced by a couple of K. However, I have
seen certain program files crunched from 80K to 20K, so large reductions are
quite possible.
Non-executable files will, of course, be ignored by the cruncher.
The aim of this cruncher is to shorten files so that they use up less disk
space, so the cruncher will only write a crunched file, back to disk, if it does
in fact use less disk space, otherwise it will generate the message "File
uncrunchable".
Uncrunching files
-----------------
When uncrunching, the uncrunched file will be written back to disk with the
same name as the crunched file had. If you don't wish this to happen then the
'd' qualifier will cause it to be written with the extension 'UCR'.
Running out of memory
---------------------
If you run out of memory try getting rid of all ram disks, desk ACCs. Copy
the cruncher onto the disk that has the files to be crunched and execute it from
there. If this fails then the only option is to upgrade your memory. A 1 Meg. ST
should be able to crunch any conceivably sized program, although a 520 may have
problems with very large program files.
I find the best "crunching" environment is to put the cruncher into a ram
disk as small as possible (i.e. one with about 3K free space) and then
inserting the disks with the programs to be crunched into the floppy drive. You
can then crunch the files by preceding the pathname with the drive number (e.g.
"A:..."). I have the cruncher write over the original files with the crunched
versions, because the crunched versions always work and if you wish to get the
original file back you can always uncrunch it. If you would rather the original
not be deleted then use the 'd' qualifier, although this means there must be
enough free space on the disk to accommodate the new crunched file.
D✓D✓D✓Di✓i✓i✓is✓s✓s✓sc✓c✓c✓cl✓l✓l✓la✓a✓a✓ai✓i✓i✓im✓m✓m✓me✓e✓e✓er✓r✓r✓r:✓:✓:✓: The author can accept no responsibility for any data loss or any
other form of damage arising from the use of this program.